
cc.Class({
    extends: cc.Component,

    properties: {
        farms:[cc.SpriteFrame],
        sup:require('SkillLauncher')
    },

    // LIFE-CYCLE CALLBACKS:

    onLoad () {
        // this.sup=cc.find('launcher',this.node).getComponent('SkillLauncher');
        this.sup.setSkillParentNode(global.GameLoop.GameMgr.no_BulletSelfLayer);
    },

    start () {

    },

    setOptions(option){
        // this.isIgnore=true;
        if(option.sup>=0){
            this.node.getComponent(cc.Sprite).spriteFrame=this.farms[option.sup];
            this.number=option.sup
        }
    },

    startFire(){
        this.sup.reset();
        var skills=global.DataConfig.monster['supLaunch'+(this.number+1)].status['0'];
        this.sup.addLauncher(skills)
    },

    stopFire(){
        this.sup.reset();
    },
    

    // update (dt) {},
});
